package com.starleague.game;

import java.util.Map;

import com.starleague.common.AbstractHasInfoProperties;

public abstract class AbstractTeam
        extends AbstractHasInfoProperties
        implements IMutableTeam
{
    private String name;

    protected AbstractTeam(String name)
    {
        this.name = name;
    }

    protected AbstractTeam()
    {
        //
    }

    @Override
    public String getName()
    {
        return this.name;
    }

    @Override
    public void setName(String name)
    {
        this.name = name;
    }

    @Override
    public Map<String, Object> infoProperties()
    {
        Map<String, Object> infoPropertyMap = super.infoProperties();
        infoPropertyMap.put("name", this.name);
        return infoPropertyMap;
    }
}
